package com.shaokel.service;

import com.shaokel.pojo.Type;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @author 少丶客
 * @ClassName TypeService
 * @Description TODO
 * @Date 2020/6/24 15:49
 * @Vesion 1.0
 */
public interface TypeService {

    //增加Type
    Type savaType(Type type);

    //删除Type
    void deleteType(Long id);

    //更新Type
    Type updateType(Long id ,Type type);

    //查找Type
    Type getType(Long id);

    //分页查询Type
    Page<Type> listType(Pageable pageable);

    //根据名称查找Type
    Type getTypeByName(String name);

    //获取所有的list
    List<Type> listType();

    List<Type> listTypeTop(Integer size);
}